function EFFECT:Init(data)
	local vOffset = data:GetOrigin()
	self.Pos = vOffset
	self.Normal = data:GetNormal()

	--WorldSound("physics/metal/metal_sheet_impact_bullet1.wav", vOffset, 79, math.Rand(110, 145))

	local emitter = ParticleEmitter(vOffset)
	emitter:SetNearClip(16, 22)
	for i=1, 32 do
        local particle = emitter:Add("effects/spark", vOffset)
		particle:SetVelocity(VectorRand() * math.Rand(0, 1400 * SCALE))
		particle:SetDieTime(math.Rand(0.1, 0.5)) 
		particle:SetStartAlpha(255)
		particle:SetEndAlpha(0)
		particle:SetStartSize(9 * SCALE)
		particle:SetEndSize(0)
		particle:SetRoll(math.Rand(0, 360))
		particle:SetRollDelta(math.Rand(-5, 5))
		particle:SetAirResistance(400 * SCALE)
		particle:SetGravity(Vector(0, 0, -10 * SCALE))
	end

	local particle = emitter:Add("effects/yellowflare", vOffset)
	particle:SetDieTime(math.Rand(0.1, 0.2))
	particle:SetStartAlpha(220)
	particle:SetEndAlpha(0)
	particle:SetStartSize(5 * SCALE)
	particle:SetEndSize(64 * SCALE)
	particle:SetRoll(math.Rand(0, 360))
	particle:SetRollDelta(math.Rand(-100, 100))

	--[[local particle1 = emitter:Add("effects/select_ring", vOffset)
	particle1:SetDieTime(math.Rand(0.1, 0.3))
	particle1:SetStartAlpha(200)
	particle1:SetEndAlpha(0)
	particle1:SetStartSize(30 * SCALE)
	particle1:SetEndSize(100 * SCALE)
	particle1:SetRoll(math.Rand(0, 360))
	particle1:SetRollDelta(math.Rand(-15, 15))]]

	emitter:Finish()

	self.DieTime = CurTime() + 0.25
end

function EFFECT:Think()
	return CurTime() < self.DieTime
end

local matFlare = Material("effects/yellowflare")
function EFFECT:Render()
	local delta = math.max(0, self.DieTime - CurTime())

	render.SetMaterial(matFlare)
	local size = (0.25 - delta) * 64 * SCALE
	local col = Color(255, 255, 255, delta * 1000)
	render.DrawQuadEasy(self.Pos, self.Normal, size, size, col)
	render.DrawQuadEasy(self.Pos, self.Normal * -1, size, size, col)
end 
